Hi!

Hi!

am 01.12.2009 21:03:24 von dmamede

Hi!
I'm trying to connect an Oracle Db with a PostgreSQL Db, by means of
Oracle heterogeneous service.
I've installed (in my oracle server) DG4ODBC which is the oracle
gateway, UnixODBC which is the driver manager... and all I need now is
the PostgreSQL driver. I've downloaded psqlodbc... but I can't
"configure" it as it says that theres a missing variable ...
"PG_CONFIG". I've found the pg_config file in my PostgreSQL server.. but
I don't know if there's any other driver to install which wouldn expect
pg_config to be there.
Both servers are Linux RHEL 4. Oracle version: 10.2.0.4... PostgreSQL
version: 8.2.4

Thanks for your help!
Daniela.

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 02.12.2009 02:20:17 von Craig Ringer

On 2/12/2009 4:03 AM, Daniela Mamede d'Almeida wrote:
> Hi!
> I'm trying to connect an Oracle Db with a PostgreSQL Db, by means of
> Oracle heterogeneous service.
> I've installed (in my oracle server) DG4ODBC which is the oracle
> gateway, UnixODBC which is the driver manager... and all I need now is
> the PostgreSQL driver. I've downloaded psqlodbc... but I can't
> "configure" it as it says that theres a missing variable ...
> "PG_CONFIG".

Possible hints:

http://www.google.com.au/search?q="PG_CONFIG"+"unixodbc"

Particularly:

http://cpansearch.perl.org/src/RKIES/UnixODBC-0.34/dbms/READ ME

.... which suggests that you must specify PG_CONFIG as an environment
variable when calling configure:

# export PG_CONFIG=/usr/local/pgsql/bin/pg_config
# ./configure

(adjust PG_CONFIG for the location of pg_config on your system).

--
Craig Ringer

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 02.12.2009 15:35:18 von dmamede

Thanks for answering!
My problem is that the Oracle Db and the PostgreSQL Db are both on=20
different servers, and I;ve been told by Oracle support that I need to=20
install the PostgreSQL driver in my Oracle server. Now I don't know how=20
to solve the PG_CONFIG error, as there's no pg_config file in the Oracle=20
server!
How can I solve this?

Thanks a lot!
Daniela.

Craig Ringer escribi=F3:
> On 2/12/2009 4:03 AM, Daniela Mamede d'Almeida wrote:
>> Hi!
>> I'm trying to connect an Oracle Db with a PostgreSQL Db, by means of
>> Oracle heterogeneous service.
>> I've installed (in my oracle server) DG4ODBC which is the oracle
>> gateway, UnixODBC which is the driver manager... and all I need now is
>> the PostgreSQL driver. I've downloaded psqlodbc... but I can't
>> "configure" it as it says that theres a missing variable ...
>> "PG_CONFIG".
>
> Possible hints:
>
> http://www.google.com.au/search?q=3D"PG_CONFIG"+"unixodbc"
>
> Particularly:
>
> http://cpansearch.perl.org/src/RKIES/UnixODBC-0.34/dbms/READ ME
>
> ... which suggests that you must specify PG_CONFIG as an environment=20
> variable when calling configure:
>
> # export PG_CONFIG=3D/usr/local/pgsql/bin/pg_config
> # ./configure
>
> (adjust PG_CONFIG for the location of pg_config on your system).
>
> --=20
> Craig Ringer

--=20
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 02.12.2009 16:00:39 von jonah.harris

--0016361644934e81620479c023f7
Content-Type: text/plain; charset=ISO-8859-1

On Wed, Dec 2, 2009 at 9:35 AM, Daniela Mamede d'Almeida <
dmamede@mecon.gov.ar> wrote:

> Thanks for answering!
> My problem is that the Oracle Db and the PostgreSQL Db are both on
> different servers, and I;ve been told by Oracle support that I need to
> install the PostgreSQL driver in my Oracle server. Now I don't know how to
> solve the PG_CONFIG error, as there's no pg_config file in the Oracle
> server!
> How can I solve this?
>

Yes, you'll have to install Postgres (or at least the Postgres client
libraries) on your Oracle server.

--
Jonah H. Harris, Senior DBA
myYearbook.com

--0016361644934e81620479c023f7
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On Wed, Dec 2, 2009 at 9:35 AM, Daniela Mamede d=
'Almeida <=
dmamede@mecon.gov.ar
>
wrote:
ote" style=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0p=
t 0.8ex; padding-left: 1ex;">
Thanks for answering!

My problem is that the Oracle Db and the PostgreSQL Db are both on differen=
t servers, and I;ve been told by Oracle support that I need to install the =
PostgreSQL driver in my Oracle server. Now I don't know how to solve th=
e PG_CONFIG error, as there's no pg_config file in the Oracle server! r>

How can I solve this?

Yes, you'll have to inst=
all Postgres (or at least the Postgres client libraries) on your Oracle ser=
ver.

--
Jonah H. Harris, Senior DBA
myYearbook.co=
m




--0016361644934e81620479c023f7--

Re: Hi!

am 02.12.2009 16:05:45 von Craig Ringer

On 2/12/2009 10:35 PM, Daniela Mamede d'Almeida wrote:
> Thanks for answering!
> My problem is that the Oracle Db and the PostgreSQL Db are both on
> different servers, and I;ve been told by Oracle support that I need to
> install the PostgreSQL driver in my Oracle server. Now I don't know how
> to solve the PG_CONFIG error, as there's no pg_config file in the Oracle
> server!

Er ... The file `pg_config' is part of the PostgreSQL package. It's
installed with the server. It's a program that should be in the server's
binary directory, in the same place as `psql'. Since you're building
pgodbc from source, I'm assuming you also built and installed PostgreSQL
from sources, so you should have it. If you installed distro binaries,
you'll probably need a -dev or -devel package for libpq too.

HOWEVER, if you installed PostgreSQL using your distro's packaging
system, you should just install psqlodbc that way too, not build it from
sources. It should be in your distro's package management system.
On my Debian and Ubuntu systems, for example, I just "apt-get install
odbc-postgresql" to install it.

If you'd given us a few basic details like what PostgreSQL version you
had, where you got it from, how you installed it, the OS and version you
were running on, etc, it might be a little bit easier to help you with
this. See:

http://wiki.postgresql.org/wiki/Guide_to_reporting_problems


--
Craig Ringer

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 04.12.2009 19:05:10 von dmamede







Hi Jonah!

I installed the client libraries, but the error is still there... The
pkg I installed is  postgresql-libs-7.4.13-2.RHEL4.1.x86_64.rpm

Do I have to do anything?



Thanks!

Daniela.



Jonah H. Harris escribió:
cite="mid:36e682920912020700o4dc0a460rdb60af4aa4f9d7ef@mail. gmail.com"
type="cite">

On Wed, Dec 2, 2009 at 9:35 AM, Daniela
Mamede d'Almeida < href="mailto:dmamede@mecon.gov.ar">dmamede@mecon.gov.ar>
wrote:

style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Thanks
for answering!

My problem is that the Oracle Db and the PostgreSQL Db are both on
different servers, and I;ve been told by Oracle support that I need to
install the PostgreSQL driver in my Oracle server. Now I don't know how
to solve the PG_CONFIG error, as there's no pg_config file in the
Oracle server!

How can I solve this?




Yes, you'll have to install Postgres (or at least the Postgres client
libraries) on your Oracle server.





--

Jonah H. Harris, Senior DBA

myYearbook.com





Re: Hi!

am 04.12.2009 20:31:44 von jonah.harris

--00163616449370bf0d0479ec28ce
Content-Type: text/plain; charset=ISO-8859-1

On Fri, Dec 4, 2009 at 1:05 PM, Daniela Mamede d'Almeida <
dmamede@mecon.gov.ar> wrote:

> I installed the client libraries, but the error is still there... The pkg
> I installed is postgresql-libs-7.4.13-2.RHEL4.1.x86_64.rpm
> Do I have to do anything?
>

Hey Daniela,

Let me update my how-to doc for you.

--
Jonah H. Harris, Senior DBA
myYearbook.com

--00163616449370bf0d0479ec28ce
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On Fri, Dec 4, 2009 at 1:05 PM, Daniela Mamede d=
'Almeida <=
dmamede@mecon.gov.ar
>
wrote:
ote" style=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0p=
t 0.8ex; padding-left: 1ex;">



=20



I installed the client libraries, but the error is still there... The
pkg I installed is=A0 postgresql-libs-7.4.13-2.RHEL4.1.x86_64.rpm

Do I have to do anything?

v>
Hey Daniela,

Let me update my how-to doc for you.

-- =

Jonah H. Harris, Senior DBA
myYearbook.com



--00163616449370bf0d0479ec28ce--

Re: Hi!

am 05.12.2009 03:28:28 von Craig Ringer

On 5/12/2009 2:05 AM, Daniela Mamede d'Almeida wrote:
> Hi Jonah!
> I installed the client libraries, but the error is still there... The
> pkg I installed is postgresql-libs-7.4.13-2.RHEL4.1.x86_64.rpm
> Do I have to do anything?

Install the PgODBC packages too, rather than trying to build PgODBC from
source. Assuming there are any for RHEL4 - I can't find a package search
like `packages.debian.org' for RHEL, but the distrowatch source package
list doesn't include unixodbc so it might not be included in the system
packages.

If you *must* install PgODBC from source, install the -dev or -devel rpm
for the client libraries too, since that should contain pg_config . You
might also need to install unixodbc; I'm not sure about that.

--
Craig Ringer

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 15.12.2009 16:21:54 von dmamede

Hi List!
After looking for a suitable pkg for a long time, I've found=20
postgresql-devel-8.4.1-1PGDG.rhel4.x86_64.rpm which sounded like what I=20
needed! But when I tried to install it, it asked for some dependencies,=20
and those dependencies asked for other dependencies... and I almost got=20
all Postgres pkg installed by the end, and that's not what I want.
Isn't there a better way to get pg_config?

Thanks a lot for your help!
Daniela.

Craig Ringer escribi=F3:
> On 5/12/2009 2:05 AM, Daniela Mamede d'Almeida wrote:
>> Hi Jonah!
>> I installed the client libraries, but the error is still there... The
>> pkg I installed is postgresql-libs-7.4.13-2.RHEL4.1.x86_64.rpm
>> Do I have to do anything?
>
> Install the PgODBC packages too, rather than trying to build PgODBC=20
> from source. Assuming there are any for RHEL4 - I can't find a package=20
> search like `packages.debian.org' for RHEL, but the distrowatch source=20
> package list doesn't include unixodbc so it might not be included in=20
> the system packages.
>
> If you *must* install PgODBC from source, install the -dev or -devel=20
> rpm for the client libraries too, since that should contain pg_config=20
> . You might also need to install unixodbc; I'm not sure about that.
>
> --=20
> Craig Ringer

--=20
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 15.12.2009 17:56:28 von Adrian Klaver

On Tuesday 15 December 2009 7:21:54 am Daniela Mamede d'Almeida wrote:
> Hi List!
> After looking for a suitable pkg for a long time, I've found
> postgresql-devel-8.4.1-1PGDG.rhel4.x86_64.rpm which sounded like what I
> needed! But when I tried to install it, it asked for some dependencies,
> and those dependencies asked for other dependencies... and I almost got
> all Postgres pkg installed by the end, and that's not what I want.
> Isn't there a better way to get pg_config?
>
> Thanks a lot for your help!
> Daniela.
>
>

The thing to keep in mind is that pg_config is just a helper program. To quote
the docs:

http://www.postgresql.org/docs/8.4/interactive/app-pgconfig. html

"The pg_config utility prints configuration parameters of the currently
installed version of PostgreSQL. It is intended, for example, to be used by
software packages that want to interface to PostgreSQL to facilitate finding
the required header files and libraries. "

In order for pg_config to work the other files/libraries need to be installed.


--
Adrian Klaver
aklaver@comcast.net

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 15.12.2009 18:16:41 von dmamede







Oracle support told me to install PostgreSQL driver in my Oracle
server. What I don't understand is what's the use of running pg_config
in a server where there's no Postgre installed.

Maybe there's another postgresql driver that wouldn't expect pg_config
to be there. I there any?



Thanks!!



Adrian Klaver escribió:

type="cite">
On Tuesday 15 December 2009 7:21:54 am Daniela Mamede d'Almeida wrote:


Hi List!
After looking for a suitable pkg for a long time, I've found
postgresql-devel-8.4.1-1PGDG.rhel4.x86_64.rpm which sounded like what I
needed! But when I tried to install it, it asked for some dependencies,
and those dependencies asked for other dependencies... and I almost got
all Postgres pkg installed by the end, and that's not what I want.
Isn't there a better way to get pg_config?

Thanks a lot for your help!
Daniela.





The thing to keep in mind is that pg_config is just a helper program. To quote
the docs:



"The pg_config utility prints configuration parameters of the currently
installed version of PostgreSQL. It is intended, for example, to be used by
software packages that want to interface to PostgreSQL to facilitate finding
the required header files and libraries. "

In order for pg_config to work the other files/libraries need to be installed.





Re: Hi!

am 15.12.2009 19:14:46 von Adrian Klaver

On Tuesday 15 December 2009 9:16:41 am Daniela Mamede d'Almeida wrote:
> Oracle support told me to install PostgreSQL driver in my Oracle server.
> What I don't understand is what's the use of running pg_config in a server
> where there's no Postgre installed. Maybe there's another postgresql driver
> that wouldn't expect pg_config to be there. I there any?
>
> Thanks!!
>

pg_config is not the problem, it is just a program to make compiling the ODBC
driver easier. You could specify the locations for the necessary files to the
configure program manually without using pg_config. The issue is that in order
to compile the driver you need the Postgres files/libraries. That being said
did you try the rpm below:

http://yum.pgsqlrpms.org/8.2/redhat/rhel-4-x86_64/postgresql -odbc-08.03.0400-1PGDG.rhel4.x86_64.rpm

Note:This is for version Postgres 8.2 which is what you originally said you are
using.

You previous email had postgresql-devel-8.4.1-1PGDG.rhel4.x86_64.rpm which is
for Postgres 8.4 and may be part of the problem.

--
Adrian Klaver
aklaver@comcast.net

--
Sent via pgsql-odbc mailing list (pgsql-odbc@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-odbc

Re: Hi!

am 13.01.2010 20:48:21 von jonah.harris

--0016e64b96de8c9c29047d110d72
Content-Type: text/plain; charset=ISO-8859-1

On Tue, Dec 15, 2009 at 12:16 PM, Daniela Mamede d'Almeida <
dmamede@mecon.gov.ar> wrote:

> Oracle support told me to install PostgreSQL driver in my Oracle server.
> What I don't understand is what's the use of running pg_config in a server
> where there's no Postgre installed.
> Maybe there's another postgresql driver that wouldn't expect pg_config to
> be there. I there any?
>

I hate the pgodbc driver and given that I spent an hour trying to get ODBCng
working with 11.2 on CentOS 5.4 x86_64 with no success, you may want to look
at this article.

I can confirm that the following works as expected, though it uses the
commercial PostgreSQL DataDirect driver:
http://eduardolegatti.blogspot.com/2009/07/abordando-o-uso-d e-database-links-em.html

--
Jonah H. Harris, Senior DBA
myYearbook.com

--0016e64b96de8c9c29047d110d72
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On Tue, Dec 15, 2009 at 12:16 PM, Daniela Mamede=
d'Almeida < ">dmamede@mecon.gov.ar> wrote:
quote" style=3D"border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt =
0pt 0.8ex; padding-left: 1ex;">



=20


Oracle support told me to install PostgreSQL driver in my Oracle
server. What I don't understand is what's the use of running pg_con=
fig
in a server where there's no Postgre installed.

Maybe there's another postgresql driver that wouldn't expect pg_con=
fig
to be there. I there any?

I hate the pgodbc =
driver and given that I spent an hour trying to get ODBCng working with 11.=
2 on CentOS 5.4 x86_64 with no success, you may want to look at this articl=
e.=A0


I can confirm that the following works as expected, though it uses the =
commercial PostgreSQL DataDirect driver:
i.blogspot.com/2009/07/abordando-o-uso-de-database-links-em. html">http://ed=
uardolegatti.blogspot.com/2009/07/abordando-o-uso-de-databas e-links-em.html=



--
Jonah H. Harris, Senior DBA
myYearbook.com
>

--0016e64b96de8c9c29047d110d72--